package org.example.booklist.model;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.format.annotation.DateTimeFormat;
import org.springframework.web.bind.annotation.RequestParam;


@Data
public class PageRequest<T> {

    private Integer pageNum = 1;

    private Integer pageSize = 10;

    private Integer offset;

    public Integer getOffset(){
        return (pageNum-1) * pageSize;
    }

}
